#! /usr/bin/ruby

def check_usage
	unless ARGV.length == 1
		puts "Usage: ruby family.rb name"
		exit
	end
end

def family (member)
	if member == 'Sam'
		puts "Father"
	elsif member == 'Amy'
		puts "Mother"
	elsif member == 'Alice'
		puts "Daughter"
	elsif member == 'Josh'
		puts "Son"
	else puts "Unknown person."
	end
end

if $0 == __FILE__
	check_usage
	family (ARGV[0])
end
